package com.bjpowernode.workbench.web.service.impl;

import com.bjpowernode.workbench.web.domain.FunnelVO;
import com.bjpowernode.workbench.web.domain.Tran;
import com.bjpowernode.workbench.web.mapper.TranMapper;
import com.bjpowernode.workbench.web.service.TranService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class TranServiceImpl implements TranService {

    @Autowired
    private TranMapper tranMapper;

    @Override
    public int insertTran(Tran tran) {
        return tranMapper.insertTran(tran);
    }

    @Override
    public List<Tran> selectTranDetailForPageByCondition(Tran tran) {
        return tranMapper.selectTranDetailForPageByCondition(tran);
    }

    @Override
    public int selectTranForCount() {
        return tranMapper.selectTranForCount();
    }

    @Override
    public Tran selectTranDetailByTranId(String id) {
        return tranMapper.selectTranDetailByTranId(id);
    }

    @Override
    public List<FunnelVO> selectCountOfTranGroupByStage() {
        return tranMapper.selectCountOfTranGroupByStage();
    }
}
